From 1d89b445615a361f0e3fbabc77496157cce34835 Mon Sep 17 00:00:00 2001 From: Keir Fraser Date: Tue, 26 May 2009 09:50:35 +0100 Subject: [PATCH] stubdom: 'file' based disk sharing Allow 'file' based disks, that are blkback based disks, to be shared between the guest domain and the stubdom. It does so exploiting the same exception introduced in the previous patch "stubdoms phy disks sharing". Now we can remove the hack in stubdom-dm that forces "file" disks to be opened using blktap instead of blkback. Signed-off-by: Stefano Stabellini --- stubdom/stubdom-dm | 4 ---- tools/hotplug/Linux/block | 6 +++--- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/stubdom/stubdom-dm b/stubdom/stubdom-dm index 0bcc1e644b..be39fff894 100644 --- a/stubdom/stubdom-dm +++ b/stubdom/stubdom-dm @@ -114,10 +114,6 @@ do vbd_dev=`xenstore-read $i/dev` vbd_front=`xenstore-read $i/frontend` vbd_devtype=`xenstore-read $vbd_front/device-type` - if [ $vbd_type = "file" ] - then - vbd_type="tap:aio" - fi if [ $j -ne 0 ] then echo -n "," >> /etc/xen/stubdoms/$domname-dm diff --git a/tools/hotplug/Linux/block b/tools/hotplug/Linux/block index 8c61744c83..e042a7ef99 100644 --- a/tools/hotplug/Linux/block +++ b/tools/hotplug/Linux/block @@ -202,13 +202,13 @@ case "$command" in p=$(xenstore_read "$XENBUS_PATH/params") mode=$(xenstore_read "$XENBUS_PATH/mode") fi + FRONTEND_ID=$(xenstore_read "$XENBUS_PATH/frontend-id") + FRONTEND_UUID=$(xenstore_read_default \ + "/local/domain/$FRONTEND_ID/vm" 'unknown') case $t in phy) dev=$(expand_dev $p) - FRONTEND_ID=$(xenstore_read "$XENBUS_PATH/frontend-id") - FRONTEND_UUID=$(xenstore_read_default \ - "/local/domain/$FRONTEND_ID/vm" 'unknown') if [ -L "$dev" ] then -- 2.30.2